<extend name="Public:base" />
<block name="title"><title>修改会员</title></block>
<block name="script">
	<script type="text/javascript">
		$(document).ready(function(){
			$('#status:checked').parents('label.btn').addClass('active');
		});
	</script>
</block>
<block name="sidebar">
	<include file="Public:sidebar" />
</block>
<block name="content">
	<div id="content" class="col-sm-8">
		<div class="panel panel-default">
			<div class="panel-heading">
				<h4 class="panel-title"><i class="glyphicon glyphicon-header"></i> 修改会员</h4>
			</div>

			<div class="panel-body">
				<form class="form-horizontal" action="{:U('User/update')}" method='post'>
					<div class="form-group">
						<label for="account" class="col-sm-2 control-label">用户名:</label>
						<div class="col-sm-5">
							<input type="text" class="form-control" placeholder="用户名" name="account" id="account" value="{$vo.account}" />
						</div>
						<label class="col-sm-2 control-label"></label>
					</div>

					<div class="form-group">
						<label for="score" class="col-sm-2 control-label">昵称:</label>
						<div class="col-sm-5">
							<input type="text" class="form-control" placeholder="昵称" name="nickname" id="nickname" value="{$vo.nickname}" />
						</div>
						<label class="col-sm-2 control-label"></label>
					</div>

					<div class="form-group">
						<label class="col-sm-2 control-label">是否启用:</label>
						<div class="btn-group col-sm-5" data-toggle="buttons">
							<label class="btn btn-primary">
								<input type="radio" name="status" id="status" <eq name="vo.status" value="1" >checked="checked"</eq> value="1" />启用
							</label>
							<label class="btn btn-danger">
								<input type="radio" name="status" id="status" <eq name="vo.status" value="0" >checked="checked"</eq> value="0" />禁用
							</label>
						</div>
						<label class="col-sm-2 control-label"></label>
					</div>

					<div class="form-group">
						<label for="roleName" class="col-sm-2 control-label">所属角色:</label>
						<div class="col-sm-3">
							<select class="form-control" name="roleId">
								<option value="0">--无--</option>
								<volist name="data" id="vo">
								<option value="{$vo['id']}" <eq name="roleId" value="$vo.id" >selected</eq>>{$vo['name']}</option>
								</volist>
							</select>
						</div>
						<label class="col-sm-2 control-label"></label>
					</div>
					<div class="form-group">
						<label class="col-sm-2 control-label"></label>
						<div class="col-sm-5">
							<input type="hidden" name="id" value="{$_GET.id}">
							<button type="submit" class="btn btn-success btn-add">保存</button>
						</div>
					</div>
				</form>
			</div>
		</div>
	</div>
</block>

